package com.qingzhuge.sms;


import com.qingzhuge.common.IBaseEnum;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

/**
 * @author : zero.xiao
 * @description :
 * @date : 2018/9/19 0019 上午 10:25
 * @modified :
 * @since :
 */
@ApiModel("短信平台类型")
public enum ESmsType implements IBaseEnum<String> {
    /**阿里云短信平台*/
    @ApiModelProperty("阿里云")
    aliyun("aliyun");

    private String value;

    ESmsType(String value) {
        this.value = value;
    }

    @Override
    public String value() {
        return value;
    }

    public static ESmsType get(String name) {
        if (name == null) {
            return null;
        }
        ESmsType[] vals = ESmsType.values();
        for (ESmsType e : vals) {
            boolean b = e.name().equals(name);
            if (b) {
                return ESmsType.valueOf(name);
            }
        }
        return null;
    }
}
